package com.atguigu.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.*;

/**
 * 用于返回字符串
 * RequestMapping + ResponseBody = RestController
 *
 * @author sx
 * @date 2022-02-20 10:59
 */
@Controller
@RequestMapping("/hello")
public class HelloController {

    @GetMapping("/hello")
    @ResponseBody
    public String hello() {
        return "hello";
    }

}
